<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        table{
            margin:50px auto;
            width: 500px;
            height: 300px;
            /* border: 1px solid palegreen; */
            border-spacing: 0;
            text-align: center;
        }
        td{
            border: 1px solid palegreen;

        }
        th{
            border: 1px solid palegreen;

        }

    </style>
</head>
<body>
    <!-- <table>
        <tr>
            <th>世界名称</th>
            <th>世界选择</th>
            <th>世界等级</th>
            <th>世界大小</th>
        </tr>
        <tr>
            <td>我的世界</td>
            <td>1世界</td>
            <td>20</td>
            <td>大</td>
        </tr>

    </table> -->
    <script>
        let wordName=prompt('请输入世界名称');
        let wordSece=prompt('请选择世界');
        let wordTj=prompt('请输入世界等级');
        let wordNc=prompt('请输入世界大小');
        let html=(`<table>
        <tr>
            <th>世界名称</th>;
            <th>世界选择</th>;
            <th>世界等级</th>;
            <th>世界大小</th>;
        </tr>
        <tr>
            <td>${wordName}</td>;
            <td>${wordSece}</td>;
            <td>${wordTj}</td>;
            <td>${wordNc}</td>;
        </tr>
    </table>`)
        document.write(html);

    </script>
</body>
</html>